package com.zeng.config;

import com.zeng.bean.Person;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;

/**
 * @author Zqm
 * @Title: PropertyValues
 * @ProjectName SpringAnnotationDriven
 * @date 2019/1/17
 * 属性赋值配置类
 */
//外部加载配置文件
@PropertySource(value = {
        "classpath:/person.properties"
})
@Configuration
public class MainConfigOfPropertyValues {

    @Bean
    public Person person(){
        return new Person();
    }
}
